<?php
$a = 'joe@example.org';
$b = 'bogus-at-exampledotorg';
$c = 'bogus@example.org';

if (filter_var($a, FILTER_SANITIZE_EMAIL)) {
    echo "This (a) sanitized email address is considered valid.\n";
}else{
    echo "no";
}

if (filter_var($b, FILTER_VALIDATE_EMAIL)) {
    echo "This sanitized email address is considered valid.";
} else {
    echo "This (b) sanitized email address is considered invalid.\n";
 

}
if (filter_var($c, FILTER_VALIDATE_EMAIL)) {
    echo "This (c) sanitized email address is considered valid.\n";
    
}else{

    echo "no";
}